<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" 
      xmlns:ui="http://java.sun.com/jsf/facelets" 
      xmlns:h="http://java.sun.com/jsf/html" 
      xmlns:f="http://java.sun.com/jsf/core">
    <h:body>
    	<ui:composition template="./templates/framework.xhtml">
			<ui:define name="content">
				<ui:include src="./templates/header.xhtml">
					<ui:param name="text" value="#{i18n['generic.back']}" />
					<ui:param name="link" value="index.xhtml" />
				</ui:include>
				<ui:fragment rendered="#{sessionBean.getKeeBookAccess('READ_WRITE')}">
					<h:form id="changePassphraseForm" styleClass="primary">
						<div>
							<h:outputLabel for="currentPassword" value="#{i18n['changePassword.current']}" />
							<h:inputSecret id="currentPassword" autocomplete="off" redisplay="true" />
						</div>
						<div>
							<h:outputLabel for="password" value="#{i18n['changePassword.new']}" />
							<h:inputSecret id="password" autocomplete="off" styleClass="switchVisibility" />
						</div>
						<div>
							<h:selectBooleanCheckbox id="passwordChecked" />
							<h:outputLabel for="passwordChecked" styleClass="checkboxLabel"><h:outputText value="#{i18n['generic.passwordChecked']}" /></h:outputLabel>
						</div>
						<div class="warn">
							<h:outputText value="#{i18n['changePassword.hint']}" />
						</div>
						<div class="buttons">
							<h:commandButton type="submit" value="#{i18n['changePassword.changeBookPassword']}" />
							<input type="button" value="#{i18n['generic.cancel']}" onclick="location.href='renamekeebook.xhtml'" />
						</div>
					</h:form>
				</ui:fragment>
			</ui:define>
		</ui:composition>
    </h:body>
</html>